package cn.gson.crm.model.dao;

import cn.gson.crm.model.pojos.ProductXq;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;
import org.springframework.transaction.annotation.Transactional;

public interface CpxqDao extends CrudRepository<ProductXq,Integer> {

    @Transactional
    @Modifying(clearAutomatically = true)
    @Query(nativeQuery = true,value = "update PRODUCT_XQ set cp_zt=0 where CPXQ_ID= ?1")
    public void xg(Integer cpId);
}
